<div>
    <x-mini-header>
        <x-slot name="url"></x-slot>
        <x-slot name="title">登录</x-slot>
    </x-mini-header>

    <form class="p-2 space-y-2 mt-2" wire:submit.prevent="submit">
        <div class="flex flex-col">
            <label for="account">账号</label>
            <input wire:model="account" class="border-b py-2 focus:outline-none focus:border-red-300 transition-all" type="text" id="account" placeholder="请输入您的登录账号" autofocus autocomplete="off">
            @error('account') <span class="text-red-600 text-sm pt-1">{{ $message }}</span> @enderror
        </div>

        <div class="flex flex-col">
            <label for="password">密码</label>
            <input wire:model="password" class="border-b py-2 focus:outline-none focus:border-red-300 transition-all" type="password" id="password" placeholder="请输入您的登录密码" autocomplete="off">
            @error('password') <span class="text-red-600 text-sm pt-1">{{ $message }}</span> @enderror
        </div>

        <div class="py-2">
            <button type="submit" class="flex items-center justify-center gap-1 w-full py-3 bg-gradient-to-r from-red-500 to-[red] text-white">
                <svg wire:loading xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-4 h-4 animate-spin">
                    <path stroke-linecap="round" stroke-linejoin="round" d="M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0l3.181 3.183a8.25 8.25 0 0013.803-3.7M4.031 9.865a8.25 8.25 0 0113.803-3.7l3.181 3.182m0-4.991v4.99"/>
                </svg>
                登录
            </button>
        </div>

        <div class="flex justify-center items-center divide-x text-sm">
            <a wire:navigate href="{{ route('register') }}" class="text-red-600 underline px-2">立即注册</a>
            <a href="" class="text-red-600 underline px-2">忘记密码</a>
        </div>
    </form>
</div>
